From b16567f978fc42a79bdbab4b2dac372dfc08a8d9 Mon Sep 17 00:00:00 2001 From: robertl Date: Wed, 26 Oct 2005 17:01:12 +0000 Subject: [PATCH] From Mike, sf.x.mh2@spamgourmet. > Since the date is taken from the RMC sentence of the PREVIOUS second, the > current implementation writes a wrong date when the time jumps from 235959 > to 000000. This can be fixed by the following patch: > --- gpsbabel/nmea.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gpsbabel/nmea.c b/gpsbabel/nmea.c index 518d86899..2a5a6008c 100644 --- a/gpsbabel/nmea.c +++ b/gpsbabel/nmea.c @@ -363,6 +363,9 @@ gprmc_parse(char *ibuf) curr_waypt->speed = speed*kts2mps; if (curr_waypt->course<=0) curr_waypt->course = course; + /* The change of date wasn't recorded when + * going from 235959 to 000000. */ + curr_waypt->creation_time = mkgmtime(&tm); } return; } -- 2.30.2